<div class="index-top">
    <div class="index-top-left pull-left">
        <div class="circle color-red pull-left"></div>
        <div class="circle color-yello pull-left"></div>
        <div class="circle color-green pull-left"></div>
        <div class="clearfix"></div>
    </div>
    <ul class="nav navbar-toolbar container">

        <li id="work-bench">
            <a href="/index">
                <span aria-hidden="true" style="margin-right:5px"
                      class="glyphicon glyphicon-home">
                </span>
                <span>工作台</span>
            </a>
        </li>
        <li id="project-management">
            <div class="dropdown nav">
                <div class="dropdown-toggle" type="button" data-toggle="dropdown" aria-haspopup="true"
                     aria-expanded="true"
                     id="dropdownMenu1">
                    <span aria-hidden="true" style="margin-right:5px"
                          class="glyphicon glyphicon-list-alt">
                    </span>
                    日常管理
                    <span class="caret"></span>
                </div>
                <ul class="dropdown-menu" aria-labelledby="dropdownMenu1">
                    <li><a href="/daily/week/index">周计划</a></li>
                    <!--<li><a href="/daily/day/index">日例会</a></li>-->
                    <!--<li><a href="/daily/word/list">文档</a></li>-->
                    <!--<li><a href="/personalTask/index">任务管理</a></li>-->
                    <li><a href="/daily/schedule/index">待办事项</a></li>
                </ul>
            </div>
        </li>


        <!--<li id="project-management">-->
        <!--<a href="/project/listAll">-->
        <!--<span aria-hidden="true" style="margin-right:5px"-->
        <!--class="glyphicon glyphicon-book">-->
        <!--</span>-->
        <!--<span>项目管理</span>-->
        <!--</a>-->
        <!--</li>-->
        <!--<li id="module-management">-->
        <!--<a href="/module/listAll">-->
        <!--<span aria-hidden="true" style="margin-right:5px"-->
        <!--class="glyphicon glyphicon-tasks">-->
        <!--</span>-->
        <!--<span>模块管理</span>-->
        <!--</a>-->
        <!--</li>-->
        <li id="system-management">
            <div class="dropdown nav">
                <div class="dropdown-toggle" type="button" data-toggle="dropdown" aria-haspopup="true"
                     aria-expanded="true"
                     id="dropdownMenu1">
                    <span aria-hidden="true" style="margin-right:5px"
                          class="glyphicon glyphicon-list-alt">
                    </span>
                    系统管理
                    <span class="caret"></span>
                </div>
                <ul class="dropdown-menu" aria-labelledby="dropdownMenu1">
                    <li><a href="/person/listAll">用户管理</a></li>
                </ul>
            </div>
        </li>

    </ul>
    <div class="index-top-right pull-right">
        <div style="padding-left:20px" class="top-cancellation pull-right">
            <a href="/logout">注销</a>
        </div>
        <div class="dropdown top-touxiang pull-right">
            <a data-target="#" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
                <span id="loginname"><%= session.loginedUser.realname %></span>
                <span class="caret"></span>
            </a>
            <ul class="dropdown-menu" aria-labelledby="dLabel">
                <li><a href="#">个人中心</a></li>
                <li><a href="/modifyPassword ">修改密码</a></li>
                <li><a href="#" id="resetPassword">重置密码</a></li>
            </ul>
        </div>
        <div class="top-icon pull-right">
            <img src="/images/index/Email.png" alt="">
        </div>
        <div class="top-icon pull-right">
            <img src="/images/index/Bell.png" alt="">
        </div>
        <div class="clearfix"></div>
    </div>
    <div class="clearfix"></div>
</div>

<script>
    $(function () {
        $('#resetPassword').click(function () {
            var loginName = $('#loginname').text();
            $.post('/password/save', {
                loginName: loginName,
                newPassword: '111111'
            }, function (result) {
                if (result.errcode === 0) {
                    location.href = '/index';
                } else {
                    location.href = '/login';
                }
            });
        })
    })
</script>